package org.simplextensions;

import java.util.HashSet;
import java.util.Set;

public abstract class Utils {

	public static String[] merge(String[] depends, String...smvsFM) {
		Set<String> dependsSet = new HashSet<String>();

		if (depends != null)
			for (String s : depends) {
				if (s != null && !s.equals(""))
					dependsSet.add(s);
			}

		if (smvsFM != null)
			for (String s : smvsFM) {
				if (s != null && !s.equals(""))
					dependsSet.add(s);
			}

		return dependsSet.toArray(new String[dependsSet.size()]);
	}

}
